package guda.house.biz.form;

import guda.house.biz.util.PriceUtil;
import guda.house.dal.dataobject.ExtraFeeDO;

import javax.validation.constraints.NotNull;

/**
 * Created by well on 16/1/21.
 */
public class ExtraFeeEditForm extends ExtraFeeForm{

    @NotNull(message = "不能为空")
    private Long feeId;

    public Long getFeeId() {
        return feeId;
    }

    public void setFeeId(Long feeId) {
        this.feeId = feeId;
    }


    public void initForm(ExtraFeeDO extraFeeDO){
        setVillageId(extraFeeDO.getVillageId());
        setFeeComment(extraFeeDO.getFeeComment());
        setVarId(extraFeeDO.getVarId());
        setFeeAmount(PriceUtil.formatCNYNoGroup(extraFeeDO.getFeeAmount()));

    }
}
